#pragma once
#include <iostream>
#include <string>
#include <sstream>
#include "SDL.h"
#include "SDLResources.h"
#include "SDLSprite.h"

class TextManager
{
#pragma region Singleton
public:
	static TextManager* GetInstance()
	{
		if(!mInstance)
		{
			mInstance = new TextManager();
		}
		return mInstance;
	}
	static void Kill()
	{
		delete mInstance;
		mInstance = 0;
	}
private:
	static TextManager* mInstance;
	TextManager();
	~TextManager();
#pragma endregion

public:
	enum RENDER_METHOD{SOLID = 0, ANTIALIAS};

	void LoadFont(std::string fontName, int size);
	void SetFontColor(SDL_Color* color);
	void SetRenderMethod(int renderMethod){mRenderMethod = renderMethod;}

	SDL_Surface* RenderText(std::string text);
private:
	TTF_Font* mFont;
	SDL_Color* mColor;
	int mRenderMethod;
};